//
//  NSString+STLogin.m
//  ZuoBiao
//
//  Created by stoneobs on 17/1/17.
//  Copyright © 2017年 shixinyun. All rights reserved.
//

#import "NSString+STLogin.h"

@implementation NSString (STLogin)
-(NSString*)safetyPhone
{
    if (self.length != 11) {
        NSLog(@"电话号码不是11位,修改失败");
        return self;
    }
    NSString * beginStr = [self substringToIndex:3];
    NSString * lastStr = [self substringFromIndex:9];
    return  [NSString stringWithFormat:@"%@****%@",beginStr,lastStr];
}
@end
